# the minimum version of CMake.
cmake_minimum_required(VERSION 3.5.0)
project(myNpmLib)

set(NATIVERENDER_ROOT_PATH ${CMAKE_CURRENT_SOURCE_DIR})
set(OHOS_ARCH "arm64-v8a")
if(DEFINED PACKAGE_FIND_FILE)
    include(${PACKAGE_FIND_FILE})
endif()
add_compile_options(
        -v
)

include_directories(${NATIVERENDER_ROOT_PATH}
                    ${NATIVERENDER_ROOT_PATH}/include
                    )

add_library(learnnapi SHARED napi_init.cpp Person.h Person.cpp)

#target_link_libraries(learnnapi PUBLIC ${CMAKE_CURRENT_SOURCE_DIR}/../../libs/${OHOS_ARCH}/libTestHMOSCompile.so)

#add_library(TestHMOSCompile SHARED IMPORTED)
#set_target_properties(TestHMOSCompile
#    PROPERTIES
#    IMPORTED_LOCATION ${CMAKE_CURRENT_SOURCE_DIR}/third_party/TestHMOSCompile/libs/${OHOS_ARCH}/libTestHMOSCompile.so)

target_link_libraries(learnnapi PUBLIC libace_napi.z.so ${CMAKE_CURRENT_SOURCE_DIR}/../../../libs/${OHOS_ARCH}/libHMOSThirdLib.so)